package com.km.yygh.msm.utils;

import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

@Component
public class MsmConstantUtils implements InitializingBean {
        //我已经再
        @Value("${tencentcloud.sms.secretId}")
        private String secretId ;

        @Value("${tencentcloud.sms.secretKey}")
        private String secretKey ;

        @Value("${tencentcloud.sms.sdkAppId}")
        private String sdkAppId;

        @Value("${tencentcloud.sms.signName}")
        private String signName;

        @Value("${tencentcloud.sms.templateId}")
        private String templateId;

        public static String SECRET_ID;
        public static String SECRET_KEY;
        public static String SDK_APPID;
        public static String SIGN_NAME;
        public static String TEMPLATE_ID;

        @Override
        public void afterPropertiesSet() throws Exception {
            SECRET_ID = secretId;
            SECRET_KEY = secretKey;
            SDK_APPID = sdkAppId;
            SIGN_NAME = signName;
            TEMPLATE_ID = templateId;
        }
    }


